/* 文档搜索工具容器作用域样式 */
.document-search-container {
  --search-gap: 1.25rem;
  padding: var(--container-padding);
}

/* 主容器布局 */
.document-search-container > .container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* 搜索区域架构 */
.document-search-container .search-wrapper {
  margin-bottom: 2.5rem;
  position: relative;
}

/* 搜索行网格布局 */
.document-search-container .doc-search-row {
  display: flex;
  gap: var(--search-gap);
  align-items: stretch;
  flex-wrap: nowrap;
}

/* 输入框容器增强 */
.document-search-container .search-field-container {
  flex: 1 1 70%;
  min-width: 360px;
  position: relative;
}

/* 内联搜索按钮样式 */


.document-search-container #search-input {
  padding-right: 45px;
}

/* 按钮组容器 */
.document-search-container .action-buttons {
  display: inline-flex;
  gap: var(--search-gap);
}

/* 文档列表网格布局 */
/* 全局文档项基础样式 */
.doc-item-x {
  padding: 1rem 0;
  margin-bottom: 0;
}

.doc-item-x:last-child {
  border-bottom: none;
}

.flex-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.5rem 0;
}

.document-search-container .doc-list {
  display: grid;
  gap: 1.5rem;
  margin-top: 2rem;
}

/* 文档项卡片样式 */
.document-search-container .doc-item-x {
  --item-padding: 1.5rem;
  padding: var(--item-padding);
  background: var(--card-bg-color);
  border: 1px solid var(--border-color);
  border-bottom: 1px solid #dee2e6 !important;
  border-radius: 0.875rem;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.document-search-container .doc-item-x:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px -4px rgba(0, 0, 0, 0.12);
}

/* 文档标题层级 */
.document-search-container .doc-title {
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--primary-color);
  margin-right: 1.5rem;
  line-height: 1.4;
  flex-grow: 1;
}

/* 响应式断点系统 */
@media (max-width: var(--desktop-breakpoint)) {
  .document-search-container .doc-search-row {
    flex-wrap: wrap;
    gap: calc(var(--search-gap) * 0.75);
  }
}

@media (max-width: var(--mobile-breakpoint)) {
  .document-search-container .action-buttons {
    gap: calc(var(--search-gap) / 2);
  }
}

/* 空状态增强 */
.document-search-container .no-results {
  padding: 3rem 2rem;
  background: var(--card-bg-color);
  border-radius: 0.875rem;
  text-align: center;
  color: var(--text-muted);
}

/* 错误提示架构 */
.document-search-container #error-message {
  padding: 1.5rem;
  border-radius: 0.875rem;
  background: color-mix(in srgb, var(--danger-color) 8%, transparent);
  border: 1px solid color-mix(in srgb, var(--danger-color) 20%, transparent);
}